package com.dg.cuckoo.admin.service.impl;

import com.dg.cuckoo.admin.dto.compilation.GovernmentMoneyDto;
import com.dg.cuckoo.admin.service.GovernProcurementService;
import com.dg.cuckoo.admin.service.GovernmentMoneyService;
import com.dg.cuckoo.common.utils.PageModel;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.web.multipart.MultipartFile;


@Service
public class GovernProcurementServiceimpl implements GovernProcurementService {

    @Autowired
    public GovernmentMoneyService governmentMoneyService;

    @Override
    public void save(GovernmentMoneyDto dto, MultipartFile[] files) throws Exception {
        governmentMoneyService.powerfulSave(dto,files);
    }

    @Override
    public void update(String id, GovernmentMoneyDto dto, MultipartFile[] files) throws Exception {
        governmentMoneyService.powerfulUpdate(id,dto,files);
    }

    @Override
    public PageModel page(Integer page, Integer pageSize) {
       return governmentMoneyService.powerfulPage(page,pageSize,3);
    }

}
